<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en_EN" lang="en_En">
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<script src="<?php echo base_url()?>js/jquery-1.6.4.min.js" type="text/javascript"></script>
		<script src="<?php echo base_url()?>js/jquery.dimensions.js" type="text/javascript"></script>
		<script src="<?php echo base_url()?>js/jquery.tooltip.js" type="text/javascript"></script>
		<script src="<?php echo base_url()?>js/highcharts.js" type="text/javascript"></script>
		<link rel="stylesheet" href="<?php echo base_url()?>css/styleadmin.css" type="text/css"/>
		<link rel="stylesheet" href="<?php echo base_url()?>js/jqueryui/css/jquery.tooltip.css" type="text/css"/>
		
		<title><?php echo $title ?></title>
		<base href="<?php echo base_url()?>" />
		<?php
		 if(!isset($husbandPresent) || $husbandPresent == null){
			$husPreTrustValue = 0;
			$husPreRespectValue = 0;
			$husPreCareValue = 0;
			$husPreCommitmentValue = 0;
			$husPreFinancialValue = 0;
			$husPreDomestricValue = 0;
			$husPreIntimacyValue = 0;
			$husPrePhysicalValue = 0;
			$husPreFunTimeValue = 0;
			$husPreBestFriendValue = 0;	
			$husPreSpiritualIntimacyValue = 0;
			$husPreConflictResolutionValue = 0;		
		 }else{
			$husPreTrustValue = $husbandPresent->trust;
			$husPreRespectValue = $husbandPresent->respect;
			$husPreCareValue = $husbandPresent->care;
			$husPreCommitmentValue = $husbandPresent->commitment;
			$husPreFinancialValue = $husbandPresent->financial_support;
			$husPreDomestricValue = $husbandPresent->domestric_support;
			$husPreIntimacyValue = $husbandPresent->intimacy;
			$husPrePhysicalValue = $husbandPresent->physical_appearance;
			$husPreFunTimeValue = $husbandPresent->fun_time_together;
			$husPreBestFriendValue = $husbandPresent->best_friend_talk;
			$husPreSpiritualIntimacyValue = $husbandPresent->spiritual_intimacy;
			$husPreConflictResolutionValue = $husbandPresent->conflict_resolution;
		 }
		 if(!isset($husbandBefore) || $husbandBefore == null){
			$husBeforeTrustValue = 0;
			$husBeforeRespectValue = 0;
			$husBeforeCareValue = 0;
			$husBeforeCommitmentValue = 0;
			$husBeforeFinancialValue = 0;
			$husBeforeDomestricValue = 0;
			$husBeforeIntimacyValue = 0;
			$husBeforePhysicalValue = 0;
			$husBeforeFunTimeValue = 0;
			$husBeforeBestFriendValue = 0;
			$husBeforeSpiritualIntimacyValue = 0;
			$husBeforeConflictResolutionValue = 0;		
		 }else{
			$husBeforeTrustValue = $husbandBefore->trust;
			$husBeforeRespectValue = $husbandBefore->respect;
			$husBeforeCareValue = $husbandBefore->care;
			$husBeforeCommitmentValue = $husbandBefore->commitment;
			$husBeforeFinancialValue = $husbandBefore->financial_support;
			$husBeforeDomestricValue = $husbandBefore->domestric_support;
			$husBeforeIntimacyValue = $husbandBefore->intimacy;
			$husBeforePhysicalValue = $husbandBefore->physical_appearance;
			$husBeforeFunTimeValue = $husbandBefore->fun_time_together;
			$husBeforeBestFriendValue = $husbandBefore->best_friend_talk;
			$husBeforeSpiritualIntimacyValue = $husbandBefore->spiritual_intimacy;
			$husBeforeConflictResolutionValue = $husbandBefore->conflict_resolution;
		 }
		 if(!isset($husbandTest3) || $husbandTest3 == null){
		 	$husTest3TrustValue = 0;
			$husTest3RespectValue = 0;
			$husTest3CareValue = 0;
			$husTest3CommitmentValue = 0;
			$husTest3FinancialValue = 0;
			$husTest3DomestricValue = 0;
			$husTest3IntimacyValue = 0;
			$husTest3PhysicalValue = 0;
			$husTest3FunTimeValue = 0;
			$husTest3BestFriendValue = 0;
			$husTest3SpiritualIntimacyValue = 0;
			$husTest3ConflictResolutionValue = 0;
		 }else{
		 	$husTest3TrustValue = $husbandTest3->trust;
			$husTest3RespectValue = $husbandTest3->respect;
			$husTest3CareValue = $husbandTest3->care;
			$husTest3CommitmentValue = $husbandTest3->commitment;
			$husTest3FinancialValue = $husbandTest3->financial_support;
			$husTest3DomestricValue = $husbandTest3->domestric_support;
			$husTest3IntimacyValue = $husbandTest3->intimacy;
			$husTest3PhysicalValue = $husbandTest3->physical_appearance;
			$husTest3FunTimeValue = $husbandTest3->fun_time_together;
			$husTest3BestFriendValue = $husbandTest3->best_friend_talk;
			$husTest3SpiritualIntimacyValue = $husbandTest3->spiritual_intimacy;
			$husTest3ConflictResolutionValue = $husbandTest3->conflict_resolution;
		 }
		 if(!isset($wifePresent) || $wifePresent == null){
			$wifePreTrustValue = 0;
			$wifePreRespectValue = 0;
			$wifePreCareValue = 0;
			$wifePreCommitmentValue = 0;
			$wifePreFinancialValue = 0;
			$wifePreDomestricValue = 0;
			$wifePreIntimacyValue = 0;
			$wifePrePhysicalValue = 0;
			$wifePreFunTimeValue = 0;
			$wifePreBestFriendValue = 0;
			$wifePreSpiritualIntimacyValue = 0;
			$wifePreConflictResolutionValue = 0;
		 }else{
			$wifePreTrustValue = $wifePresent->trust;
			$wifePreRespectValue = $wifePresent->respect;
			$wifePreCareValue = $wifePresent->care;
			$wifePreCommitmentValue = $wifePresent->commitment;
			$wifePreFinancialValue = $wifePresent->financial_support;
			$wifePreDomestricValue = $wifePresent->domestric_support;
			$wifePreIntimacyValue = $wifePresent->intimacy;
			$wifePrePhysicalValue = $wifePresent->physical_appearance;
			$wifePreFunTimeValue = $wifePresent->fun_time_together;
			$wifePreBestFriendValue = $wifePresent->best_friend_talk;
			$wifePreSpiritualIntimacyValue = $wifePresent->spiritual_intimacy;
			$wifePreConflictResolutionValue = $wifePresent->conflict_resolution;
		 }
		 if(!isset($wifeBefore) || $wifeBefore == null){
			$wifeBeforeTrustValue = 0;
			$wifeBeforeRespectValue = 0;
			$wifeBeforeCareValue = 0;
			$wifeBeforeCommitmentValue = 0;
			$wifeBeforeFinancialValue = 0;
			$wifeBeforeDomestricValue = 0;
			$wifeBeforeIntimacyValue = 0;
			$wifeBeforePhysicalValue = 0;
			$wifeBeforeFunTimeValue = 0;
			$wifeBeforeBestFriendValue = 0;
			$wifeBeforeSpiritualIntimacyValue = 0;
			$wifeBeforeConflictResolutionValue = 0;
		 }else{
			$wifeBeforeTrustValue = $wifeBefore->trust;
			$wifeBeforeRespectValue = $wifeBefore->respect;
			$wifeBeforeCareValue = $wifeBefore->care;
			$wifeBeforeCommitmentValue = $wifeBefore->commitment;
			$wifeBeforeFinancialValue = $wifeBefore->financial_support;
			$wifeBeforeDomestricValue = $wifeBefore->domestric_support;
			$wifeBeforeIntimacyValue = $wifeBefore->intimacy;
			$wifeBeforePhysicalValue = $wifeBefore->physical_appearance;
			$wifeBeforeFunTimeValue = $wifeBefore->fun_time_together;
			$wifeBeforeBestFriendValue = $wifeBefore->best_friend_talk;
			$wifeBeforeSpiritualIntimacyValue = $wifeBefore->spiritual_intimacy;
			$wifeBeforeConflictResolutionValue = $wifeBefore->conflict_resolution;
		 }
		 if(!isset($wifeTest3) || $wifeTest3 == null){
			$wifeTest3TrustValue = 0;
			$wifeTest3RespectValue = 0;
			$wifeTest3CareValue = 0;
			$wifeTest3CommitmentValue = 0;
			$wifeTest3FinancialValue = 0;
			$wifeTest3DomestricValue = 0;
			$wifeTest3IntimacyValue = 0;
			$wifeTest3PhysicalValue = 0;
			$wifeTest3FunTimeValue = 0;
			$wifeTest3BestFriendValue = 0;
			$wifeTest3SpiritualIntimacyValue = 0;
			$wifeTest3ConflictResolutionValue = 0;
		 }else{
			$wifeTest3TrustValue = $wifeTest3->trust;
			$wifeTest3RespectValue = $wifeTest3->respect;
			$wifeTest3CareValue = $wifeTest3->care;
			$wifeTest3CommitmentValue = $wifeTest3->commitment;
			$wifeTest3FinancialValue = $wifeTest3->financial_support;
			$wifeTest3DomestricValue = $wifeTest3->domestric_support;
			$wifeTest3IntimacyValue = $wifeTest3->intimacy;
			$wifeTest3PhysicalValue = $wifeTest3->physical_appearance;
			$wifeTest3FunTimeValue = $wifeTest3->fun_time_together;
			$wifeTest3BestFriendValue = $wifeTest3->best_friend_talk;
			$wifeTest3SpiritualIntimacyValue = $wifeTest3->spiritual_intimacy;
			$wifeTest3ConflictResolutionValue = $wifeTest3->conflict_resolution;
		 }
		 ?>
		<script type="text/javascript">
			var husChart;
			$(document).ready(function() {
				husChart = new Highcharts.Chart({
					colors: [
						'#DE208C',
						'#52308C',
						'#ff9900',
						'#9966cc', 
						'#89A54E', 
						'#80699B', 
						'#3D96AE', 
						'#DB843D', 
						'#92A8CD', 
						'#A47D7C', 
						'#B5CA92'
					],
					chart: {
						renderTo: 'husband-container',
						defaultSeriesType: 'line',
						marginRight: 0,
						marginLeft: -10,
						height: 325,
						width: 985,
						plotBackgroundImage: '<?php echo base_url()?>css/imgs/highchart-bg.png',
						plotBorderColor: '#FFFFFF',
						className : "chart-container",
						marginBottom: 0
					},
					title: {
						text: '',
						x: 5 //center
					},
					subtitle: {
						text: '',
						x: -20
					},
					symbols: [
						      	'circle',
						      	'circle',
						      	'diamond', 
						      	'square', 
						      	'triangle', 
						      	'triangle-down'
						      ],
					xAxis: {
						lineColor: '#FF0000',
						lineWidth: 0,
						labels: {
							style: {
								color: '#FFFFFF'
							}
						},
						tickLength : 0,
						categories: ['Trust', 'Respect', 'Caring', 'Commitment', 'Financial Support', 'Domestic Support', 
							'Intimacy', 'Physical Appearance Attractive', 'Fun/Quality Time Together', '"Best Friend" Talk', 'Spiritual Intimacy', 'Conflict Resolution']
					},
					yAxis: {
						title: {
							text: ''
						},
						labels: {
				            align: 'right',
				            x: 35,
				            y: 5
				        },
						lineColor: '#FF0000',
						lineWidth: 0,
						max : 10.1,
						min: -0.1,
						showLastLabel: false,
						showFirstLabel: false,
						tickLength : 1,
						tickInterval: 1,
						gridLineWidth: 0
					},
					tooltip: {
						formatter: function() {
				                return '<b>'+ this.series.name +'</b><br/>'+
								this.x +': '+ this.y;
						}
					},
					legend: {
						layout: 'vertical',
						align: 'right',
						verticalAlign: 'top',
						x: -100,
						y: -15,
						borderWidth: 0
					},
					series: [{
						name: 'Current Relationship',
						data: [<?php echo $husPreTrustValue/10 ?>, <?php echo $husPreRespectValue/10 ?>, <?php echo $husPreCareValue/10 ?>, <?php echo $husPreCommitmentValue/10 ?>, <?php echo $husPreFinancialValue/10 ?>, <?php echo $husPreDomestricValue/10 ?>, <?php echo $husPreIntimacyValue/10 ?>, <?php echo $husPrePhysicalValue/10 ?>, <?php echo $husPreFunTimeValue/10 ?>, <?php echo $husPreBestFriendValue/10 ?>, <?php echo $husPreSpiritualIntimacyValue/10 ?>, <?php echo $husPreConflictResolutionValue/10 ?>]
						}, {
						name: 'Desired Relationship',
						data: [<?php echo $husBeforeTrustValue/10 ?>, <?php echo $husBeforeRespectValue/10 ?>, <?php echo $husBeforeCareValue/10 ?>, <?php echo $husBeforeCommitmentValue/10 ?>, <?php echo $husBeforeFinancialValue/10 ?>, <?php echo $husBeforeDomestricValue/10 ?>, <?php echo $husBeforeIntimacyValue/10 ?>, <?php echo $husBeforePhysicalValue/10 ?>, <?php echo $husBeforeFunTimeValue/10 ?>, <?php echo $husBeforeBestFriendValue/10 ?>, <?php echo $husBeforeSpiritualIntimacyValue/10 ?>, <?php echo $husBeforeConflictResolutionValue/10 ?>]
					}]
				});				
			});
			var wifeChart;
			$(document).ready(function() {
				husChart = new Highcharts.Chart({
					colors: [
						'#DE208C',
						'#52308C',
						'#ff9900',
						'#9966cc', 
						'#ff9900', 
						'#89A54E', 
						'#80699B', 
						'#3D96AE', 
						'#DB843D', 
						'#92A8CD', 
						'#A47D7C', 
						'#B5CA92'
					],
					chart: {
						renderTo: 'wife-container',
						defaultSeriesType: 'line',
						marginRight: 0,
						marginLeft: -10,
						height: 325,
						width: 985,
						plotBackgroundImage: '<?php echo base_url()?>css/imgs/highchart-bg.png',
						plotBorderColor: '#FFFFFF',
						className : "chart-container",
						marginBottom: 0
					},
					title: {
						text: '',
						x: 5 //center
					},
					subtitle: {
						text: '',
						x: -20
					},
					symbols: [
						      	'circle',
						      	'circle',
						      	'diamond', 
						      	'square', 
						      	'triangle', 
						      	'triangle-down'
						      ],
					xAxis: {
						lineColor: '#FFFFFF',
						lineWidth: 0,
						tickLength : 0,
						labels: {
							style: {
								color: '#FFFFFF'
							}
						},
						categories: ['Trust', 'Respect', 'Caring', 'Commitment', 'Financial Support', 'Domestic Support', 
							'Intimacy', 'Physical Appearance Attractive', 'Fun/Quality Time Together', '"Best Friend" Talk', 'Spiritual Intimacy', 'Conflict Resolution']
					},
					yAxis: {
						title: {
							text: ''
						},
						lineColor: '#FF0000',
						labels: {
				            align: 'right',
				            x: 35,
				            y: 5
				        },
						lineWidth: 0,
						max : 10.1,
						min: -0.1,
						showLastLabel: false,
						showFirstLabel: false,
						tickLength : 1,
						tickInterval: 1,
						gridLineWidth: 0
					},
					tooltip: {
						formatter: function() {
				                return '<b>'+ this.series.name +'</b><br/>'+
								this.x +': '+ this.y;
						}
					},
					legend: {
						layout: 'vertical',
						align: 'right',
						verticalAlign: 'top',
						x: -100,
						y: -15,
						borderWidth: 0
					},
					series: [{
						name: 'Current Relationship',
						data: [<?php echo $wifePreTrustValue/10 ?>, <?php echo $wifePreRespectValue/10 ?>, <?php echo $wifePreCareValue/10 ?>, <?php echo $wifePreCommitmentValue/10 ?>, <?php echo $wifePreFinancialValue/10 ?>, <?php echo $wifePreDomestricValue/10 ?>, <?php echo $wifePreIntimacyValue/10 ?>, <?php echo $wifePrePhysicalValue/10 ?>, <?php echo $wifePreFunTimeValue/10 ?>, <?php echo $wifePreBestFriendValue/10?>, <?php echo $wifePreSpiritualIntimacyValue/10?>, <?php echo $wifePreConflictResolutionValue/10?>]
						}, {
						name: 'Desired Relationship',
						data: [<?php echo $wifeBeforeTrustValue/10 ?>, <?php echo $wifeBeforeRespectValue/10 ?>, <?php echo $wifeBeforeCareValue/10 ?>, <?php echo $wifeBeforeCommitmentValue/10 ?>, <?php echo $wifeBeforeFinancialValue/10 ?>, <?php echo $wifeBeforeDomestricValue/10 ?>, <?php echo $wifeBeforeIntimacyValue/10 ?>, <?php echo $wifeBeforePhysicalValue/10 ?>, <?php echo $wifeBeforeFunTimeValue/10 ?>, <?php echo $wifeBeforeBestFriendValue/10?>, <?php echo $wifeBeforeSpiritualIntimacyValue/10?>, <?php echo $wifeBeforeConflictResolutionValue/10?>]
					}]
				});				
			});
			$(document).ready(function() {
				$(".indicator-label-item > a").each(function(index) {
					$(this).bind({
						click: function() {
							$(".indicator-label-item > a").removeClass("indicator-marked");
							$(this).addClass("indicator-marked");
							return false;
						}
					});
				});
				$("span.indicator-title").each(function(index){
					$(this).tooltip({
						top: 10, 
					    left: 5,
					    extraClass: "tooltip-text"
					});
				});
			});
		</script>
	</head>
	<body id="client-list">
		<div id="wrapper">
			<div id="header-wrapper">
				<?php include_once('include/header_admin.php') ?>
			</div>
			<div id="content">
				<p class="bold-text"><?php echo $wife->first_name.' '.$wife->last_name ?> <?php echo $wifePresent ? "(".date("m/d/Y h:mA",$wifePresent->update_date).")": "" ?> and <?php echo $husband->first_name.' '.$husband->last_name ?> <?php echo $husbandPresent ? "(".date("m/d/Y h:mA", $husbandPresent->update_date).")": "" ?></p>
				<?php
					if($husbandPresent == null || $husbandBefore == null){
				?>
					<p><span class="notice"><?php echo $husband->first_name.' '.$husband->last_name ?>  did not complete the test yet<span></p>
				<?php
					}
				?>
				<?php
					if($wifePresent == null || $wifeBefore == null){
				?>
					<p><span class="notice"><?php echo $wife->first_name.' '.$wife->last_name ?>  did not complete the test yet<span></p>
				<?php
					}
				?>
				
				<div class="client-result">
					<p><span class="client-summary">Summary</span></p>

					<p><span id="indicator1-result" title="<?php echo $this->lang->line('result_word_description_trust')?>" class="indicator-title">Trust:</span></p>
					<p><?php echo $wife->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($wifeBeforeTrustValue, $wifePreTrustValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($wifeBeforeTrustValue, $wifePreTrustValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($wifeBeforeTrustValue, $wifePreTrustValue);?></span> satisfied in trusting <?php echo $husband->first_name?>.</p>
					<p class="test3-result"><?php echo $husband->first_name?> thinks that <?php echo $wife->first_name?> is <?php echo formatTest3Result($husTest3TrustValue); ?> satisfied in trusting him.</p>
					<p><?php echo $husband->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($husBeforeTrustValue, $husPreTrustValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($husBeforeTrustValue, $husPreTrustValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($husBeforeTrustValue, $husPreTrustValue);?></span> satisfied in trusting <?php echo $wife->first_name?>.</p>
					<p class="test3-result"><?php echo $wife->first_name?> thinks that <?php echo $husband->first_name?> is <?php echo formatTest3Result($wifeTest3TrustValue) ?> satisfied in trusting her.</p>
					
					<p><span id="indicator2-result" title="<?php echo $this->lang->line('result_word_description_respect')?>" class="indicator-title">Respect:</span></p>
					<p><?php echo $wife->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($wifeBeforeRespectValue, $wifePreRespectValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($wifeBeforeRespectValue, $wifePreRespectValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($wifeBeforeRespectValue, $wifePreRespectValue);?></span> satisfied in <?php echo $husband->first_name?>'s respect towards her.</p>
					<p class="test3-result"><?php echo $husband->first_name?> thinks that <?php echo $wife->first_name?> is <?php echo formatTest3Result($husTest3RespectValue); ?> satisfied in his respect towards her.</p>
					<p><?php echo $husband->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($husBeforeRespectValue, $husPreRespectValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($husBeforeRespectValue, $husPreRespectValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($husBeforeRespectValue, $husPreRespectValue);?></span> satisfied in <?php echo $wife->first_name?>'s respect towards him.</p>
					<p class="test3-result"><?php echo $wife->first_name?> thinks that <?php echo $husband->first_name?> is <?php echo formatTest3Result($wifeTest3RespectValue); ?> satisfied in her respect towards him.</p>
					
					<p><span id="indicator3-result" title="<?php echo $this->lang->line('result_word_description_caring')?>" class="indicator-title">Caring:</span></p>
					<p><?php echo $wife->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($wifeBeforeCareValue, $wifePreCareValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($wifeBeforeCareValue, $wifePreCareValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($wifeBeforeCareValue, $wifePreCareValue);?></span> satisfied with how <?php echo $husband->first_name?> shows caring for her.</p>
					<p class="test3-result"><?php echo $husband->first_name?> thinks that <?php echo $wife->first_name?> is <?php echo formatTest3Result($husTest3CareValue); ?> satisfied with how he shows caring for her.</p>
					<p><?php echo $husband->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($husBeforeCareValue, $husPreCareValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($husBeforeCareValue, $husPreCareValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($husBeforeCareValue, $husPreCareValue);?></span> satisfied with how <?php echo $wife->first_name?> shows caring for him.</p>
					<p class="test3-result"><?php echo $wife->first_name?> thinks that <?php echo $husband->first_name?> is <?php echo formatTest3Result($wifeTest3CareValue); ?> satisfied with how she shows caring for him.</p>
					
					<p><span id="indicator4-result" title="<?php echo $this->lang->line('result_word_description_commitment')?>" class="indicator-title">Commitment:</span></p>
					<p><?php echo $wife->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($wifeBeforeCommitmentValue, $wifePreCommitmentValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($wifeBeforeCommitmentValue, $wifePreCommitmentValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($wifeBeforeCommitmentValue, $wifePreCommitmentValue);?></span> satisfied in <?php echo $husband->first_name?>'s commitment to their relationship.</p>
					<p class="test3-result"><?php echo $husband->first_name?> thinks that <?php echo $wife->first_name?> is <?php echo formatTest3Result($husTest3CommitmentValue); ?> satisfied in his commitment to their relationship.</p>
					<p><?php echo $husband->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($husBeforeCommitmentValue, $husPreCommitmentValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($husBeforeCommitmentValue, $husPreCommitmentValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($husBeforeCommitmentValue, $husPreCommitmentValue);?></span> satisfied in <?php echo $wife->first_name?>'s commitment to their relationship.</p>
					<p class="test3-result"><?php echo $wife->first_name?> thinks that <?php echo $husband->first_name?> is <?php echo formatTest3Result($wifeTest3CommitmentValue); ?> satisfied in her commitment to their relationship.</p>
					
					<p><span id="indicator5-result" title="<?php echo $this->lang->line('result_word_description_financial_support')?>" class="indicator-title">Financial Support:</span></p>
					<p><?php echo $wife->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($wifeBeforeFinancialValue, $wifePreFinancialValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($wifeBeforeFinancialValue, $wifePreFinancialValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($wifeBeforeFinancialValue, $wifePreFinancialValue);?></span> satisfied with <?php echo $husband->first_name?>'s financial support in their relationship.</p>
					<p class="test3-result"><?php echo $husband->first_name?> thinks that <?php echo $wife->first_name?> is <?php echo formatTest3Result($husTest3FinancialValue); ?> satisfied with his financial support in their relationship.</p>
					<p><?php echo $husband->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($husBeforeFinancialValue, $husPreFinancialValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($husBeforeFinancialValue, $husPreFinancialValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($husBeforeFinancialValue, $husPreFinancialValue);?></span> satisfied with <?php echo $wife->first_name?>'s financial support in their relationship.</p>
					<p class="test3-result"><?php echo $wife->first_name?> thinks that <?php echo $husband->first_name?> is <?php echo formatTest3Result($wifeTest3FinancialValue); ?> satisfied with her financial support in their relationship.</p>
					
					<p><span id="indicator6-result" title="<?php echo $this->lang->line('result_word_description_domestic_support')?>" class="indicator-title">Domestic Support:</span></p>
					<p><?php echo $wife->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($wifeBeforeDomestricValue, $wifePreDomestricValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($wifeBeforeDomestricValue, $wifePreDomestricValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($wifeBeforeDomestricValue, $wifePreDomestricValue);?></span> satisfied with <?php echo $husband->first_name?>'s domestic support in their relationship.</p>
					<p class="test3-result"><?php echo $husband->first_name?> thinks that <?php echo $wife->first_name?> is <?php echo formatTest3Result($husTest3DomestricValue); ?> satisfied in his domestic support in their relationship.</p>
					<p><?php echo $husband->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($husBeforeDomestricValue, $husPreDomestricValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($husBeforeDomestricValue, $husPreDomestricValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($husBeforeDomestricValue, $husPreDomestricValue);?></span> satisfied with <?php echo $wife->first_name?>'s domestic support in their relationship.</p>
					<p class="test3-result"><?php echo $wife->first_name?> thinks that <?php echo $husband->first_name?> is <?php echo formatTest3Result($wifeTest3DomestricValue); ?> satisfied in her domestic support in their relationship.</p>
					
					<p><span id="indicator7-result" title="<?php echo $this->lang->line('result_word_description_intimacy')?>" class="indicator-title">Intimacy:</span></p>
					<p><?php echo $wife->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($wifeBeforeIntimacyValue, $wifePreIntimacyValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($wifeBeforeIntimacyValue, $wifePreIntimacyValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($wifeBeforeIntimacyValue, $wifePreIntimacyValue);?></span> satisfied in how <?php echo $husband->first_name?> provides sexual and emotional fulfilment to her.</p>
					<p class="test3-result"><?php echo $husband->first_name?> thinks that <?php echo $wife->first_name?> is <?php echo formatTest3Result($husTest3IntimacyValue); ?> satisfied in how he provides sexual and emotional fulfilment to her.</p>
					<p><?php echo $husband->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($husBeforeIntimacyValue, $husPreIntimacyValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($husBeforeIntimacyValue, $husPreIntimacyValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($husBeforeIntimacyValue, $husPreIntimacyValue);?></span> satisfied in how <?php echo $wife->first_name?> provides sexual and emotional fulfilment to him.</p>
					<p class="test3-result"><?php echo $wife->first_name?> thinks that <?php echo $husband->first_name?> is <?php echo formatTest3Result($wifeTest3IntimacyValue); ?> satisfied in how she provides sexual and emotional fulfilment to him.</p>
					
					<p><span id="indicator8-result" title="<?php echo $this->lang->line('result_word_description_physical_appearance_attractiveness')?>" class="indicator-title">Physical Appearance/Attractiveness:</span></p> 
					<p><?php echo $wife->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($wifeBeforePhysicalValue, $wifePrePhysicalValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($wifeBeforePhysicalValue, $wifePrePhysicalValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($wifeBeforePhysicalValue, $wifePrePhysicalValue);?></span> satisfied in <?php echo $husband->first_name?>'s physical appearance/attractiveness.</p>
					<p class="test3-result"><?php echo $husband->first_name?> thinks that <?php echo $wife->first_name?> is <?php echo formatTest3Result($husTest3PhysicalValue); ?> satisfied in his physical appearance/attractiveness.</p>                        
					<p><?php echo $husband->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($husBeforePhysicalValue, $husPrePhysicalValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($husBeforePhysicalValue, $husPrePhysicalValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($husBeforePhysicalValue, $husPrePhysicalValue);?></span> satisfied in <?php echo $wife->first_name?>'s physical appearance/attractiveness.</p>
					<p class="test3-result"><?php echo $wife->first_name?> thinks that <?php echo $husband->first_name?> is <?php echo formatTest3Result($wifeTest3PhysicalValue); ?> satisfied in her physical appearance/attractiveness.</p>
					
					<p><span id="indicator9-result" title="<?php echo $this->lang->line('result_word_description_fun_quality_time_together')?>" class="indicator-title">Fun/Quality Time Together:</span></p>
					<p><?php echo $wife->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($wifeBeforeFunTimeValue, $wifePreFunTimeValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($wifeBeforeFunTimeValue, $wifePreFunTimeValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($wifeBeforeFunTimeValue, $wifePreFunTimeValue);?></span> satisfied in how she and <?php echo $husband->first_name?> have fun/quality time together.</p>
					<p class="test3-result"><?php echo $husband->first_name?> thinks that <?php echo $wife->first_name?> is <?php echo formatTest3Result($husTest3FunTimeValue); ?> satisfied in how he and <?php echo $wife->first_name?> have fun/quality time together.</p>
					<p><?php echo $husband->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($husBeforeFunTimeValue, $husPreFunTimeValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($husBeforeFunTimeValue, $husPreFunTimeValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($husBeforeFunTimeValue, $husPreFunTimeValue);?></span> satisfied in how he and <?php echo $wife->first_name?> have fun/quality time together.</p>
					<p class="test3-result"><?php echo $wife->first_name?> thinks that <?php echo $husband->first_name?> is <?php echo formatTest3Result($wifeTest3FunTimeValue); ?> satisfied in how she and <?php echo $husband->first_name?> have fun/quality time together.</p>
					
					<p><span id="indicator10-result" title="<?php echo $this->lang->line('result_word_description_best_friend_talk')?>" class="indicator-title">"Best Friend Talk":</span></p>
					<p><?php echo $wife->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($wifeBeforeBestFriendValue, $wifePreBestFriendValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($wifeBeforeBestFriendValue, $wifePreBestFriendValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($wifeBeforeBestFriendValue, $wifePreBestFriendValue);?></span> satisfied in having open conversation and sharing all her glories and worries with <?php echo $husband->first_name?>.</p>
					<p class="test3-result"><?php echo $husband->first_name?> thinks that <?php echo $wife->first_name?> is <?php echo formatTest3Result($husTest3BestFriendValue); ?> satisfied in having open conversation and sharing all his glories and worries with <?php echo $wife->first_name?>.</p>
					<p><?php echo $husband->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($husBeforeBestFriendValue, $husPreBestFriendValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($husBeforeBestFriendValue, $husPreBestFriendValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($husBeforeBestFriendValue, $husPreBestFriendValue);?></span> satisfied in having open conversation and sharing all his glories and worries with <?php echo $wife->first_name?>.</p>
					<p class="test3-result"><?php echo $wife->first_name?> thinks that <?php echo $husband->first_name?> is <?php echo formatTest3Result($wifeTest3BestFriendValue); ?> satisfied in having open conversation and sharing all her glories and worries with <?php echo $husband->first_name?>.</p>
					
					<p><span id="indicator11-result" title="<?php echo $this->lang->line('result_word_description_spiritual_intimacy')?>" class="indicator-title">Spiritual Intimacy:</span></p>
					<p><?php echo $wife->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($wifeBeforeSpiritualIntimacyValue, $wifePreSpiritualIntimacyValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($wifeBeforeSpiritualIntimacyValue, $wifePreSpiritualIntimacyValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($wifeBeforeSpiritualIntimacyValue, $wifePreSpiritualIntimacyValue);?></span> satisfied in her Spiritual Intimacy with <?php echo $husband->first_name?>.</p>
					<p class="test3-result"><?php echo $husband->first_name?> thinks that <?php echo $wife->first_name?> is <?php echo formatTest3Result($husTest3SpiritualIntimacyValue); ?> satisfied in their Spiritual Intimacy.</p>
					<p><?php echo $husband->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($husBeforeSpiritualIntimacyValue, $husPreSpiritualIntimacyValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($husBeforeSpiritualIntimacyValue, $husPreSpiritualIntimacyValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($husBeforeSpiritualIntimacyValue, $husPreSpiritualIntimacyValue);?></span> satisfied in his Spiritual Intimacy with <?php echo $wife->first_name?>.</p>
					<p class="test3-result"><?php echo $wife->first_name?> thinks that <?php echo $husband->first_name?> is <?php echo formatTest3Result($wifeTest3SpiritualIntimacyValue); ?> satisfied in their Spiritual Intimacy.</p>
					
					<p><span id="indicator12-result" title="<?php echo $this->lang->line('result_word_description_conflict_resolution')?>" class="indicator-title">Conflict Resolution:</span></p>
					<p><?php echo $wife->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($wifeBeforeConflictResolutionValue, $wifePreConflictResolutionValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($wifeBeforeConflictResolutionValue, $wifePreConflictResolutionValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($wifeBeforeConflictResolutionValue, $wifePreConflictResolutionValue);?></span> satisfied in how she and <?php echo $husband->first_name?> resolve conflict in their relationship.</p>
					<p class="test3-result"><?php echo $husband->first_name?> thinks that <?php echo $wife->first_name?> is <?php echo formatTest3Result($husTest3ConflictResolutionValue); ?> satisfied in how they resolve conflict in their relationship.</p>
					<p><?php echo $husband->first_name?>- <span class="indicator-mark<?php echo (calSatisfied($husBeforeConflictResolutionValue, $husPreConflictResolutionValue) == 0)?" zero-mark":""?><?php echo (calSatisfied($husBeforeConflictResolutionValue, $husPreConflictResolutionValue) >= 100)?" hundred-mark":""?>"><?php echo calSatisfiedText($husBeforeConflictResolutionValue, $husPreConflictResolutionValue);?></span> satisfied in how they resolve conflict in their relationship.</p>
					<p class="test3-result"><?php echo $wife->first_name?> thinks that <?php echo $husband->first_name?> is <?php echo formatTest3Result($wifeTest3ConflictResolutionValue); ?> satisfied in how they resolve conflict in their relationship.</p>
				</div>
				<p>&nbsp;</p>
				<p class="bold-text">
					<?php echo $wife->first_name.' '.$wife->last_name ?> <?php echo $wifePresent ? "(".date("m/d/Y h:mA",$wifePresent->update_date).")": "" ?>
				</p>
				<div id="wife-chart">
					<div id="wife-container" style="margin: 0 auto"></div>
					<div class="clear"></div>
					<div id="indicator-label">
						<div class="indicator-label-item indicator-label-item-first"><a id="indicator1" href="#"><span>Trust</span></a></div>
						<div class="indicator-label-item"><a id="indicator2" href="#"><span>Respect</span></a></div>
						<div class="indicator-label-item"><a id="indicator3" href="#"><span>Caring</span></a></div>
						<div class="indicator-label-item"><a id="indicator4" href="#"><span>Commitment</span></a></div>
						<div class="indicator-label-item"><a id="indicator5" href="#"><span>Financial Support</span></a></div>
						<div class="indicator-label-item"><a id="indicator6" href="#"><span>Domestic Support</span></a></div>
						<div class="indicator-label-item"><a id="indicator7" href="#"><span>Intimacy</span></a></div>
						<div class="indicator-label-item"><a id="indicator8" href="#"><span>Physical Appearance Attractive</span></a></div>
						<div class="indicator-label-item"><a id="indicator9" href="#"><span>Fun/Quality Time Together</span></a></div>
						<div class="indicator-label-item"><a id="indicator10" href="#"><span>"Best Friend" Talk</span></a></div>
						<div class="indicator-label-item"><a id="indicator11" href="#"><span>Spiritual Intimacy</span></a></div>
						<div class="indicator-label-item"><a id="indicator12" href="#"><span>Conflict Resolution</span></a></div>
						<div class="clear"></div>
					</div>
				</div>
				
				<?php if($husband != null) ?>
				<p class="bold-text">
					<?php echo $husband->first_name.' '.$husband->last_name ?> <?php echo $husbandPresent ? "(".date("m/d/Y h:mA", $husbandPresent->update_date).")": "" ?>
				</p>
				
				<div id="husband-chart">
					<div id="husband-container" margin: 0 auto"></div>
					<div class="clear"></div>
					<div id="indicator-label">
						<div class="indicator-label-item indicator-label-item-first"><a id="indicator1" href="#"><span>Trust</span></a></div>
						<div class="indicator-label-item"><a id="indicator2" href="#"><span>Respect</span></a></div>
						<div class="indicator-label-item"><a id="indicator3" href="#"><span>Caring</span></a></div>
						<div class="indicator-label-item"><a id="indicator4" href="#"><span>Commitment</span></a></div>
						<div class="indicator-label-item"><a id="indicator5" href="#"><span>Financial Support</span></a></div>
						<div class="indicator-label-item"><a id="indicator6" href="#"><span>Domestic Support</span></a></div>
						<div class="indicator-label-item"><a id="indicator7" href="#"><span>Intimacy</span></a></div>
						<div class="indicator-label-item"><a id="indicator8" href="#"><span>Physical Appearance Attractive</span></a></div>
						<div class="indicator-label-item"><a id="indicator9" href="#"><span>Fun/Quality Time Together</span></a></div>
						<div class="indicator-label-item"><a id="indicator10" href="#"><span>"Best Friend" Talk</span></a></div>
						<div class="indicator-label-item"><a id="indicator11" href="#"><span>Spiritual Intimacy</span></a></div>
						<div class="indicator-label-item indicator-label-item-last"><a id="indicator12" href="#"><span>Conflict Resolution</span></a></div>
						<div class="clear"></div>
					</div>
				</div>
				
				<p class="print-link">You may click here to print your results: <a href="#" onclick="window.print();return false">print</a></p>
				<div class="clear"></div>
			</div>
			<div id="footer-wrapper">
				<?php include_once('include/footer_admin.php') ?>
			</div>
		</div>
	</body>
</html>